<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<title>layui</title>
	<meta name="renderer" content="webkit">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	<link rel="stylesheet" href="__static/lib/layui-v2.5.5/css/layui.css" media="all">
	<link rel="stylesheet" href="__static/css/public.css" media="all">
	<style>
		.layui-form-pane .layui-form-label {
			width: 90px;
		}
	</style>
</head>
<body>
<div class="layuimini-container"> 
	<div class="layuimini-main">
		<table class="layui-hide" id="currentTableId" lay-filter="currentTableFilter"></table>
		
	</div>
</div>
<script src="__static/lib/layui-v2.5.5/layui.js" charset="utf-8"></script>
<script src="__static/js/lay-config.js?v=1.0.4" charset="utf-8"></script>
<script src="__static/js/man.js" charset="utf-8"></script>
<script>

	var $,form,table,laydate
	layui.use(['form', 'table', 'tableSelect', 'laydate'], function () {
		$ = layui.jquery , form = layui.form , table = layui.table , laydate = layui.laydate
		 var customer_id = {$Request.get.customer_id};
		 var sell_time = {$Request.get.sell_time};
		  table.render({
				elem: '#currentTableId',
				id:'items_list',
				url: '{:url("sell_info")}?t=json',
				method : 'post',
				where:{customer_id:customer_id,sell_time:sell_time},
				toolbar: '#toolbarDemo',
				totalRow: true,
				cols: [[
					{ field: 'sell_time', title: '销售时间' ,  totalRowText: '合计',templet: function (d) {
	                    return date("Y-m-d",d.sell_time) 
	            	}},
					{ field: 'customer_name', title: '客户名称' },
					{ field: 'num', title: '销售数量',totalRow: true},
					{ field: 'total', title: '销售总价',totalRow: true},
					
				    { field: 'note', title: '备注'},
				    { field: 'media_name', title: '销售'}
				]],
				limit: 30,
				page: true,
				skin: 'line'
			});
		
		 
		
		
		

	});
	
	function get_load(msg){
		table.reload('items_list', {
			  url: '{:url("sell_info")}?t=json',
			});
		layer.msg(msg, {icon: 6});
	}
	
	
</script>

</body>
</html>